package net.pinnoocle.playdao.entity.shopPc;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import net.pinnoocle.playdao.entity.group.UpdateGroup;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import java.util.List;

/**
 * @author ye
 * @Description
 * @create 2021-10-20 19:58
 */
@Data
public class SaveScriptParams {

    @ApiModelProperty(value = "剧本id")
    @NotNull(message = "剧本id不能为空",groups = UpdateGroup.class)
    private String scriptId;

    @ApiModelProperty(value = "剧本名称",required = true)
    @NotNull(message = "剧本名称不能为空")
    private String scriptName;

    @ApiModelProperty(value = "剧本简介")
    private String scriptIntro;

    @ApiModelProperty(value = "剧本封面图",required = true)
    @NotNull(message = "请上传剧本封面图")
    private String coverImage;

    @ApiModelProperty(value = "剧本题材",required = true)
    @NotNull(message = "请选择至少一个题材")
    private String scriptLabelId;

    @ApiModelProperty(value = "剧本类型")
    private String scriptCateId;

    @ApiModelProperty(value = "剧本难易级别")
    private String scriptLevelId;

    @ApiModelProperty(value = "剧本价格",required = true)
    @NotNull(message = "剧本价格不能为空")
    @DecimalMin(value = "0.1",message = "最低价格必须大于等于0.1")
    private Double price;

    @ApiModelProperty(value = "剧本会员价格")
    private Double priceVip;

    @ApiModelProperty(value = "价格说明")
    private String priceExplain;

    @ApiModelProperty(value = "剧本发行商",required = true)
    @NotNull(message = "剧本发行商不能为空")
    private String publisher;

    @ApiModelProperty(value = "剧本人数",required = true)
    @NotNull(message = "剧本人数不能为空")
    @Min(value = 1,message = "剧本人数至少1人")
    private Integer startNumber;

    @ApiModelProperty(value = "剧本时长")
    private Double scriptTime;

    @ApiModelProperty(value = "剧本字数")
    private Integer scriptWordsNum;

    @ApiModelProperty("是否推荐 0 否 1 推荐")
    private Integer isHot;

    @ApiModelProperty("是否是新本 0 否 1 是")
    private Integer isNew;

    @ApiModelProperty(value = "剧本介绍",required = true)
    @NotNull(message = "剧本介绍不能为空")
    private String content;

    @ApiModelProperty(value = "排序值")
    private Integer sort;

    @ApiModelProperty(value = "剧本角色",required = true)
    @NotNull(message = "请添加至少1个剧本角色")
    private List<SaveScriptRoleParams> roleParams;
}
